package kr.co.mustgo.domain.payment;

import java.io.Serializable;
import java.util.Date;

public class Payment implements Serializable {
	private String paymentMeans; 
	private Date paymentDay; 
	private int paymentMoney; 
	private String reserveCode;//예약번호 
	private String productCode;//상품코드
	
	public Payment(){}
	
	public Payment(String paymentMeans, Date paymentDay, int paymentMoney,
			String reserveCode, String productCode) {
		super();
		this.paymentMeans = paymentMeans;
		this.paymentDay = paymentDay;
		this.paymentMoney = paymentMoney;
		this.reserveCode = reserveCode;
		this.productCode = productCode;
	}

	public String getPaymentMeans() {
		return paymentMeans;
	}

	public void setPaymentMeans(String paymentMeans) {
		this.paymentMeans = paymentMeans;
	}

	public Date getPaymentDay() {
		return paymentDay;
	}

	public void setPaymentDay(Date paymentDay) {
		this.paymentDay = paymentDay;
	}

	public int getPaymentMoney() {
		return paymentMoney;
	}

	public void setPaymentMoney(int paymentMoney) {
		this.paymentMoney = paymentMoney;
	}

	public String getReserveCode() {
		return reserveCode;
	}

	public void setReserveCode(String reserveCode) {
		this.reserveCode = reserveCode;
	}

	public String getProductCode() {
		return productCode;
	}

	public void setProductCode(String productCode) {
		this.productCode = productCode;
	}

	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result
				+ ((paymentDay == null) ? 0 : paymentDay.hashCode());
		result = prime * result
				+ ((paymentMeans == null) ? 0 : paymentMeans.hashCode());
		result = prime * result + paymentMoney;
		result = prime * result
				+ ((productCode == null) ? 0 : productCode.hashCode());
		result = prime * result
				+ ((reserveCode == null) ? 0 : reserveCode.hashCode());
		return result;
	}

	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		Payment other = (Payment) obj;
		if (paymentDay == null) {
			if (other.paymentDay != null)
				return false;
		} else if (!paymentDay.equals(other.paymentDay))
			return false;
		if (paymentMeans == null) {
			if (other.paymentMeans != null)
				return false;
		} else if (!paymentMeans.equals(other.paymentMeans))
			return false;
		if (paymentMoney != other.paymentMoney)
			return false;
		if (productCode == null) {
			if (other.productCode != null)
				return false;
		} else if (!productCode.equals(other.productCode))
			return false;
		if (reserveCode == null) {
			if (other.reserveCode != null)
				return false;
		} else if (!reserveCode.equals(other.reserveCode))
			return false;
		return true;
	}

	public String toString() {
		return "Payment [paymentMeans=" + paymentMeans + ", paymentDay="
				+ paymentDay + ", paymentMoney=" + paymentMoney
				+ ", reserveCode=" + reserveCode + ", productCode="
				+ productCode + "]";
	}
	
	
}
